package it.uniba.di.mas.jpnde.core;

public class PlaceEvent implements IDeliverable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	public static final short TYPE_INPUT=0;
	public static final short TYPE_OUTPUT=1;
	
	private short type=TYPE_INPUT;
	private String id="";
	
	private String agentId="";
	private String managerId="";
	
	private long delay=0;
	private String auto="N";
	private String route="";
	
	public short getType() {
		return type;
	}

	public void setType(short type) {
		this.type = type;
	}
	
	@Override
	public String getId() {
		// TODO Auto-generated method stub
		return id;
	}
	
	public void setId(String id) {
		this.id = id;
	}
	
	public void setAgentId(String agentId) {
		// TODO Auto-generated method stub
		this.agentId=agentId;
	}
	
	public String getAgentId() {
		return agentId;
	}
	
	public void setManagerId(String managerId) {
		this.managerId = managerId;
	}
	
	public String getManagerId() {
		return managerId;
	}
	
	public long getDelay() {
		return delay;
	}

	public void setDelay(long delay) {
		this.delay = delay;
	}

	public String getAuto() {
		return auto;
	}

	public void setAuto(String auto) {
		this.auto = auto;
	}

	public String getRoute() {
		return route;
	}

	public void setRoute(String route) {
		this.route = route;
	}

	public boolean isOutType(){
		return type==TYPE_OUTPUT;
	}
	
	public boolean isAuto(){
		return auto.equalsIgnoreCase("Y");
	}
	
	@Override
	public String toString() {
		return "Event [id=" + id + ", delay=" + delay + ", auto=" + auto
				+ ", managerId=" + managerId
				+ ", route=" + route + ", type=" + type + "]";
	}

}
